package ae.pcfc.etks.online.common.domain;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * TTscDepartmentsId entity. @author Mohtisham.Salahria
 */
@Entity
@Table(name = "T_TSC_CLIENT_ROLE_DEPT_MAPPING", schema = "TSC_RW")
public class TTscClientRoleToDepartmentMap implements java.io.Serializable {

	// Fields

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private String clientRoleId;
	private TTscDepartments department;
	private String isOwnerDepartment;
	private String status;

	// Constructors

	/** default constructor */
	public TTscClientRoleToDepartmentMap() {
	}

	public TTscClientRoleToDepartmentMap(String clientRoleId,
			TTscDepartments department, String isOwnerDepartment, String status) {
		super();
		this.clientRoleId = clientRoleId;
		this.department = department;
		this.isOwnerDepartment = isOwnerDepartment;
		this.status = status;
	}

	// Property accessors
	@Id
	@Column(name = "CLIENT_ROLE_ID", nullable = true, length = 10)
	public String getClientRoleId() {
		return clientRoleId;
	}

	public void setClientRoleId(String clientRoleId) {
		this.clientRoleId = clientRoleId;
	}
	@Id
	@ManyToOne(fetch = FetchType.EAGER)
	@JoinColumn(name = "DEPT_ID")
	public TTscDepartments getDepartment() {
		return department;
	}

	public void setDepartment(TTscDepartments department) {
		this.department = department;
	}
	@Column(name = "IS_OWNER_DEPT", nullable = true, length = 10)
	public String getIsOwnerDepartment() {
		return isOwnerDepartment;
	}

	public void setIsOwnerDepartment(String isOwnerDepartment) {
		this.isOwnerDepartment = isOwnerDepartment;
	}
	@Column(name = "STATUS", nullable = true, length = 10)
	public String getStatus() {
		return this.status;
	}

	public void setStatus(String status) {
		this.status = status;
	}
}